/**
 *
 */
package hichecker.ui.components.custom_table.table_cell_editor;

import hichecker.ui.components.custom_table.column_class.Points;

import javax.swing.JTextField;

/**
 *
 */
public class PointsEditor extends AbstractTableCellEditor {

	public PointsEditor() {
		comp.setHorizontalAlignment(JTextField.RIGHT);
	}

	@Override
	public boolean isValidInput() {
		return Points.isPoints(comp.getText());
	}

	@Override
	protected String getModifiedInput() {
		return "" + Points.parsePoints(comp.getText());
	}

}
